#ifndef Controller_H
#define Controller_H

#include <IceUtil/Mutex.h>
#include <vector>

using namespace std;

typedef struct{
  string renderer;
  string status;
  int p2p;
  int workUnit;
}info;

class Controller : public IceUtil::Mutex
{
 public:
  Controller();
  void setImage(string imagePath);
  void setFinished(bool f);
  void setStatus(string renderer, string status);
  void incP2P(string renderer);
  void setWorkUnit(string renderer, int workUnit);
  void setRenderer(string renderer);
  bool getFinished();
  string getImage();
  vector<info> getRenderers();
  void reset();
  ~Controller();

 private:
  string image;
  vector<info> renderers;
  bool finished;
};

#endif
